package com.example.sixtrainingdemo.entity;

import java.util.ArrayList;
import java.util.List;

public class Round {
   int id;
   String message;
   List<RoundPhoto> roundphotoList;

   public int getId() {
      return id;
   }

   public void setId(int id) {
      this.id = id;
   }
   public String getMessage() {
      return message;
   }

   public void setMessage(String message) {
      this.message = message;
   }

   public List<RoundPhoto> getRoundPhotoList() {
      return roundphotoList;
   }

   public void setPhotoList(List<RoundPhoto> roundphotoList) {
      this.roundphotoList = roundphotoList;
   }

   public void addRoundPhoto(RoundPhoto roundphoto) {
      if (roundphotoList == null) {
         roundphotoList = new ArrayList<>();
      }
      roundphotoList.add(roundphoto);
   }

   @Override
   public String toString() {
      return "Round{" +
              "message='" + message + '\'' +
              ",roundphotoList=" + (roundphotoList == null ? null : roundphotoList.size()) +
              '}';
   }
}
